﻿<!--
Copyright (c) Microsoft Corporation. All rights reserved
-->

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">

<head>
    <title></title>
    <script src="/js/scenario2-inAppPurchase.js"></script>
</head>

<body class="win-type-body">
    <div id="scenarioView">
        <div>
            <h2 id="sampleHeader" class="win-type-subheader">Description:</h2>
            <div id="scenarioDescription">
                In-app purchase
            </div>
        </div>
        <div id="scenarioContent">
            <p>
                This scenario shows any in-app products that are sellable by this product.
                Once one is selected from the list, a purchase can be attempted on it.
            </p>
            <p>
                <button id="getAssociatedProductsButton" class="win-button">Get Associated Add-Ons</button>
            </p>
            <p>
                <button id="purchaseAddOnButton" class="win-button">Purchase Selected Add-On</button>
            </p>
            <p>
                <div id="productTemplate" data-win-control="WinJS.Binding.Template">
                    <h4 data-win-bind="innerText: formattedTitle"/>
                </div>
                <div id="productsListView" class="win-selectionstylefilled" data-win-control="WinJS.UI.ListView" data-win-options="{
                    selectionMode: 'single',
                    tapBehavior: 'toggleSelect',
                    layout: { type: WinJS.UI.ListLayout },
                    itemTemplate: select ('#productTemplate')}"></div>

                <div id="productsListView" data-win-control="WinJS.UI.ListView"></div>
            </p>
        </div>
    </div>
</body>

</html>
